package com.px.tc_ip;

import java.net.InetAddress;
import java.net.UnknownHostException;

public class IInet {
    public static void main(String[] args) {
        try {
            InetAddress inetAddress=InetAddress.getLocalHost();
            String a=inetAddress.getHostAddress();
            System.out.println(a);
        } catch (UnknownHostException e) {
            e.printStackTrace();
        }
    }
}
